﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Input;

namespace Southridge.View 
{

    public static class DocumentCommands
    {

    } 
    public static class NavigationCommands
    {

        static BackViewCommand _back;  
        public static BackViewCommand Back
        {
            get
            {
                if (_back == null)
                    _back = new BackViewCommand(); 
                return _back; 
            } 
        } 
    } 
    public class BackViewCommand : ICommand 
    {
        #region ICommand Members

        public bool CanExecute(object parameter)
        {
            return true; 
        }

        public event EventHandler CanExecuteChanged;

        public void Execute(object parameter)
        {
            ViewManager.Current.Transition ( ViewManager.Current.BackView ) ;
        }

        #endregion
    }
}
